﻿using WeiBeeCommon.Core;

namespace Core
{
    public class SaveTokenHelper
    {
        public static void Saver(OAuthBase oAuth, string token, string tokenSecret)
        {
            if (oAuth is OAuthQQ)
            {
                SettingHelper.QQToken = token;
                SettingHelper.QQTokenSecret = tokenSecret;
                SettingHelper.Save();
            }
            if( oAuth is OAuthSina)
            {
                SettingHelper.Token = token;
                SettingHelper.TokenSecret = tokenSecret;
                SettingHelper.Save();
            }
            if( oAuth is OAuthSohu)
            {
                SettingHelper.SohuToken = token;
                SettingHelper.SohuTokenSecret = tokenSecret;
                SettingHelper.Save();
            }
        }
    }
}
